import Vue from 'vue'
import Router from 'vue-router'
import index from '@/components/index'
import dynamic from '@/components/dynamic'
import raise from '@/components/raise'
import unused from '@/components/unused'
import release from '@/components/release'
import releaseDynamic from '@/components/release-dynamic'
import releaseRaise from '@/components/release-raise'
import releaseUnused from '@/components/release-unused'
import host from '@/components/host'
import My from '@/components/my'
import wallet from '@/components/wallet'
import register from '@/components/register'
import login from '@/components/login'
import setting from '@/components/setting'
import personal from '@/components/personal'
import personalSetting from '@/components/personal-setting'
import passwordForget from '@/components/password-forget'
import mygoods from '@/components/mygoods'
import raiseGoods from '@/components/raise-goods'
import attestation from '@/components/attestation'
import dynamicDetails from '@/components/details/dynamic-details'
import raiseDetails from '@/components/details/raise-details'
import unusedDetails from '@/components/details/unused-details'
import unusedBuy from '@/components/unuseds/unused-buy'
import addSite from '@/components/unuseds/add-site'
import unusedGoods from '@/components/unuseds/unused-goods'
import addFriend from '@/components/addFriend'
import friendRelease from '@/components/unuseds/friend-release'
import chatContent from '@/components/unuseds/chat-content'
import releaseNews from '@/components/release-news'
import opinion from '@/components/opinion'
import raiseSearch from '@/components/details/raise-search'
import unusedSearch from '@/components/details/unused-search'
import pay from '@/components/pay'


Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/host',
      component: host,
      children: [
        {path: '/', component: index},
        {path: '/index', component: index},
        {path: '/dynamic', component: dynamic},
        {path: '/raise', component: raise},
        {path: '/unused', component: unused}
      ]
    },
    {path: '/', component: login},
    {path: '/release', component: release},
    {path: '/releaseDynamic', component: releaseDynamic},
    {path: '/releaseRaise', component: releaseRaise},
    {path: '/releaseUnused', component: releaseUnused},
    {path: '/My', component: My},
    {path: '/wallet', component: wallet},
    {path: '/register', component: register},
    {path: '/login', component: login},
    {path: '/setting', component: setting},
    {path: '/personal', component: personal},
    {path: '/personalSetting', component: personalSetting},
    {path: '/passwordForget', component: passwordForget},
    {path: '/mygoods', component: mygoods},
    {path: '/raiseGoods', component: raiseGoods},
    {path: '/attestation', component: attestation},
    {path: '/dynamicDetails', component: dynamicDetails},
    {path: '/raiseDetails', component: raiseDetails},
    {path: '/unusedDetails', component: unusedDetails},
    {path: '/unusedBuy', component: unusedBuy},
    {path: '/addSite', component: addSite},
    {path: '/unusedGoods', component: unusedGoods},
    {path: '/addFriend', component: addFriend},
    {path: '/friendRelease', component: friendRelease},
    {path: '/chatContent', component: chatContent},
    {path: '/releaseNews', component: releaseNews},
    {path: '/opinion', component: opinion},
    {path: '/raiseSearch', component: raiseSearch},
    {path: '/unusedSearch', component: unusedSearch},
    {path: '/pay', component: pay}
  ]
})


// path: path.join(__dirname, 'www')
// 至

//  path: path.resolve(__dirname, 'www'),